<?php defined('APP_VERSION') OR die('No Access'); ?>
<?php $this->templateBlock('Comm:header'); ?>
<div class="main page-asa Fix">
  <div class="section">
    <div class="section-inner">
      <div class="box searchList searchResult searchList-v1009 thumbModeView" id="searchList">
      	<div class="box">
			<!--基本资料_S-->
			<form method="post" id="baseform" enctype="multipart/form-data" action="<?php echo $this->baseUrl('index', 'girl');?>">
			<div class="base_material_v3" id="base_info">
			  <div class="setup_title bor">
			    <h4>基本资料</h4>
			  </div>
			  <div class="fn_basicinfo">
			    <table>
			      <tbody>
			        <tr>
			          <td class="basicinfo_title">昵称：</td>
			          <td>
			          	<div class="basicinfo_box box_nickname">
			              <div id="nick_name" class="nickname_vip">
			                <input type="text" value="" name="nickname" id="nickname" class="textinput" />
			                <label></label>
			              </div>
			            </div>
			          </td>
			        </tr>
			        <tr>
			          <td class="td_crossline bor3 basicinfo_title">年龄：</td>
			          <td class="td_crossline bor3">
			          	<div id="sex_con" class="basicinfo_box">
			            	<input type="text" style="width: 50px;" value="" id="age" name="age" class="textinput" />
			            	<label></label>
			            </div>
			          </td>
			        </tr>
			        <tr>
			          <td class="td_crossline bor3 basicinfo_title">籍贯：</td>
			          <td class="td_crossline bor3">
			          	<div id="hometown_address" class="basicinfo_box">
			              <select id="jiguan_guojia" name="jiguan_guojia" style="width: 120px;"></select>
			              <label></label>
			              <select id="jiguan_sheng" name="jiguan_sheng" style="width: 110px;"></select>
			              <label></label>
			              <select id="jiguan_shi" name="jiguan_shi" style="width: 110px;"></select>
			              <label></label>
			            </div>
			            </td>
			        </tr>
			        <tr>
			          <td class="td_crossline bor3 basicinfo_title">所在地：</td>
			          <td class="td_crossline bor3">
			          	<div id="suozaidi_address" class="basicinfo_box">
			              <select disabled="disabled" id="suozaidi_guojia" name="suozaidi_guojia" style="width: 120px;"></select>
			              <label> </label>
			              <select disabled="disabled" id="suozaidi_sheng" name="suozaidi_sheng" style="width: 110px;"></select>
			              <label> </label>
			              <select id="suozaidi_city" name="suozaidi_city" style="width: 110px;"></select>
			              <label> </label>
			            </div>         
			          </td>
			        </tr>
			        <tr>
			          <td class="td_crossline bor3 basicinfo_title"><label>身材：</label></td>
			          <td class="td_crossline bor3">
			             <div class="basicinfo_box">
			     			身高&nbsp;<input type="text" value="" id="shengao" name="shengao" style="width: 65px;" class="textinput" />&nbsp;(厘米)
			     			体重&nbsp;<input type="text" value="" id="tizhong" name="tizhong" style="width: 65px;" class="textinput" />&nbsp;(公斤)
			     			胸围&nbsp;<input type="text" value="" id="xiongwei" name="xiongwei" style="width: 65px;" class="textinput" />&nbsp;(罩杯)
							<label style="display: block;"></label>
			            </div>
			          </td>
			        </tr>
			        <tr>
			          <td class="td_crossline bor3 basicinfo_title"><label for="">服务：</label></td>
			          <td class="td_crossline bor3">
			          	<div class="basicinfo_box">
							<input type="text" style="width: 70%;" value="" name="fuwu" id="fuwu" class="textinput" />
							<label></label>
			            </div>
			           </td>
			        </tr>
			        <tr id="love_day_tr">
			          <td class="basicinfo_title"><label for="">标签：</label></td>
			          <td>
			          	<div class="basicinfo_box">
			          		<input name="tag[]" type="checkbox" value="六九" />六九&nbsp;
			          		<input name="tag[]" type="checkbox" value="三通" />三通&nbsp;
			          		<input name="tag[]" type="checkbox" value="KJ" />KJ&nbsp;
			          		<input name="tag[]" type="checkbox" value="SW" />SW&nbsp;
			          		<input name="tag[]" type="checkbox" value="ML" />ML&nbsp;
			          		<input name="tag[]" type="checkbox" checked="checked" value="聊天" />聊天
			            </div>
			          </td>
			        </tr>
			        <tr>
			          <td class="basicinfo_title">QQ：</td>
			          <td>
			          <input type="text" onblur="this.className='textinput'" onfocus="this.className='textinput input_focus'" class="textinput" id="qq" name="qq" />
			            <span id="career_txt_count" class="point"></span>
			          </td>
			        </tr>
			        <tr>
			          <td class="basicinfo_title">手机：</td>
			          <td>
			          <input type="text" onblur="this.className='textinput'" onfocus="this.className='textinput input_focus'" class="textinput" id="shouji" name="shouji" />
			            <span id="company_txt_count" class="point"></span>
			          </td>
			        </tr>
			        <tr>
			          <td class="basicinfo_title">照片：</td>
			          <td>
						<input type="file" name="women[]" size="45" style="border: 1px solid black;" />
			          </td>
			        </tr>
			        <tr>
			          <td class="basicinfo_title">照片：</td>
			          <td>
						<input type="file" name="women[]" size="45" style="border: 1px solid black;" />
			          </td>
			        </tr>
			        <tr>
			          <td class="basicinfo_title">照片：</td>
			          <td>
						<input type="file" name="women[]" size="45" style="border: 1px solid black;" />
						<div style="display: inline; margin-left: 5px;"><a href="javascript:void(0);" onclick="addImages(this);">添加图片</a></div>
			          </td>
			        </tr>
			        <tr>
			          <td class="basicinfo_title">简介：</td>
			          <td>
			          	<input type="text" style="width: 80%;" onblur="this.className='textinput'" onfocus="this.className='textinput input_focus'" class="textinput" id="jianjie" name="jianjie" />
			            <span id="cpy_address_count" class="point"></span>
			          </td>
			        </tr>
			      </tbody>
			    </table>
			    <p class="base_submit">
			      <input name="validate_code" type="hidden" value="<?php echo $this->data['validate_code'];?>" />
			      <button class="bt_tx2" style="background: wheat;" type="button" onclick="formsubmit();" id="base_save">保存</button>
			    </p>
			  </div>
			</div>
			</form>    	
      	</div>
      </div>
    </div>
  </div>
  <div class="aside aside-left">
    <!--Start505ModuleID-->
    <p><a onclick="pageTracker._trackPageview('dp_shanghai_search_c_leftbanner');" href="http://www.dianping.com/Redirect/4048" target="_blank"><img alt="周边快查" src="http://i1.dpfile.com/cms/20121011/622012436614.jpg"></a></p>
    <!--End505ModuleID-->
    <!--Start1049ModuleID-->
    <p><a onclick="pageTracker._trackPageview('dp_shanghai_search_c_weekly');" href="http://www.dianping.com/events/gonglue/shanghai/01/" target="_blank"><img alt="上海美食攻略" src="http://i1.dpfile.com/cms/20120831/559546661250.jpg"></a></p>
    <!--End1049ModuleID-->
  </div>
  <div class="aside aside-right" id="asideR">
	<!-- 广告类容开始 -->
	<div class="DPMKT" style="display: none;">
	  <ul class="DPMKT-list dl-txt">
	    <li class="DPMKT-item-txt">
	      <div class="di-title"><a href="http://www.dianping.com/promo/168400" kid="124754" rel="nofollow" target="_blank" onclick="pageTracker._trackPageview('dp_search_rk_上海_丽人_个性写真');document.hippo.mv('ad_c','124754_10');">美和利和服摄影工作室</a></div>
	      <div class="di-desc"><a href="http://www.dianping.com/promo/168400" kid="124754" rel="nofollow" target="_blank" onclick="pageTracker._trackPageview('dp_search_rk_上海_丽人_个性写真');document.hippo.mv('ad_c','124754_10');">促销套餐庆祝【点评冲千人】<br>
	        专业和服摄影写真优惠券下载中</a></div>
	      <div class="di-misc"><a href="http://www.dianping.com/promo/168400" kid="124754" rel="nofollow" target="_blank" onclick="pageTracker._trackPageview('dp_search_rk_上海_丽人_个性写真');document.hippo.mv('ad_c','124754_10');">QQ:1509894218</a></div>
	    </li>
	    <li class="DPMKT-item-txt">
	      <div class="di-title"><a href="http://t.dianping.com/deal/60554" kid="127459" rel="nofollow" target="_blank" onclick="pageTracker._trackPageview('dp_search_rk_上海_丽人_个性写真');document.hippo.mv('ad_c','127459_10');">森芭水下摄影</a></div>
	      <div class="di-desc"><a href="http://t.dianping.com/deal/60554" kid="127459" rel="nofollow" target="_blank" onclick="pageTracker._trackPageview('dp_search_rk_上海_丽人_个性写真');document.hippo.mv('ad_c','127459_10');">水中的你，很不同~！<br>
	        森芭水下摄影团购火热进行时！</a></div>
	      <div class="di-misc"><a href="http://t.dianping.com/deal/60554" kid="127459" rel="nofollow" target="_blank" onclick="pageTracker._trackPageview('dp_search_rk_上海_丽人_个性写真');document.hippo.mv('ad_c','127459_10');">021-57677792</a></div>
	    </li>
	  </ul>
	</div>
	<!-- 广告类容结束 -->
	<!-- 广告类容开始 -->
	<div class="J_mkt" data-mkt-list="adType, cityId, shopType, uri" data-mkt-adtype="116" data-mkt-cityid="1" data-mkt-shoptype="50" data-mkt-uri="/mkt/ajax/getItems"></div>
	<!-- 广告类容结束 -->
	<!-- 广告类容开始 -->
	<div class="DPMKT">
	  <ul class="DPMKT-list dl-img">
	    <li class="DPMKT-item-img"><a href="http://t.dianping.com/deal/67839" kid="120701" rel="nofollow" title="FC" target="_blank" onclick="pageTracker._trackPageview('dp_search_sbutton_上海_丽人');document.hippo.mv('ad_c','120701_91');"><img src="http://p.dpfile.com/awbrand/2012-09-29/634845281995926250.jpg" alt="FC" border="0"></a></li>
	    <li class="DPMKT-item-img"><a href="http://www.dianping.com/promo/156272" kid="111761" rel="nofollow" title="张玉珊修身堂（长宁龙之梦" target="_blank" onclick="pageTracker._trackPageview('dp_search_sbutton_上海_丽人');document.hippo.mv('ad_c','111761_91');"><img src="http://p.dpfile.com/awbrand/2012-05-28/634738243032803750.jpg" alt="张玉珊修身堂（长宁龙之梦" border="0"></a></li>
	    <li class="DPMKT-item-img"><a href="http://www.dianping.com/promo/167747" kid="118768" rel="nofollow" title="蓓然美" target="_blank" onclick="pageTracker._trackPageview('dp_search_sbutton_上海_丽人');document.hippo.mv('ad_c','118768_91');"><img src="http://p.dpfile.com/awbrand/2012-10-09/634853869315783750.jpg" alt="蓓然美" border="0"></a></li>
	    <li class="DPMKT-item-img"><a href="http://www.dianping.com/promo/168545" kid="131784" rel="nofollow" title="东瀛造型护肤连锁机构/东" target="_blank" onclick="pageTracker._trackPageview('dp_search_sbutton_上海_丽人');document.hippo.mv('ad_c','131784_91');"><img src="http://p.dpfile.com/awbrand/2012-10-18/634861793949999668.jpg" alt="东瀛造型护肤连锁机构/东" border="0"></a></li>
	  </ul>
	</div>
	<!-- 广告类容结束 -->
  </div>
</div>
<?php $this->templateBlock('Comm:footer'); ?>
<script type="text/javascript" src="js/city.js"></script>
<script type="text/javascript" src="js/jquery-1.8.2.min.js"></script>
<script type="text/javascript">
function addImages(obj) {
	parentTrObj = $(obj).parent().parent().parent();
	html = '<tr class="imagelist">';
	html += '<td class="basicinfo_title">照片：</td>';
	html += '<td>';
	html += '<input type="file" name="women[]" size="45" style="border: 1px solid black;" />';
	html += '<div style="display: inline; margin-left: 5px;"><a href="javascript:void(0);" onclick="removeImages(this);">删除</a></div>';
	html += '</td>';
	html += '</tr>';
	if ($('tr.imagelist').length > 6) {
		alert('最多上传10张图片.');
	} else {
		parentTrObj.after(html);
	}
}

function removeImages(obj) {
	$(obj).parent().parent().parent().remove();
}

$('#nickname').click(function() {
	input_val = $.trim($(this).val());
	if (input_val == '') $(this).next().html('<font color="red">请输入您的昵称.</font>');
	$(this).val(input_val)
}).blur(function() {
	input_val = $.trim($(this).val());
	if (input_val == '') $(this).next().html('<font color="red">请输入您的昵称.</font>');
	if (input_val != '') {
		if (input_val.length > 12) $(this).next().html('<font color="red">请输入12个以内的字符.</font>');
		if (input_val.length < 2) $(this).next().html('<font color="red">请输入2个以上的字符.</font>');
		if (input_val.length > 1 && input_val.length < 13) $(this).next().html('<font color="green">输入正确</font>');
	}
	$(this).val(input_val);
});

$('#age').click(function(){
	input_val = $.trim($(this).val());
	if (input_val == '') $(this).next().html('<font color="red">请输入您的年纪.两位数字</font>');
	$(this).val(input_val);
}).blur(function(){
	input_val = $.trim($(this).val());
	num_pat = /\d{2,2}/;
	if (num_pat.exec(input_val) == null) {input_val = '';} else {input_val = num_pat.exec(input_val)};
	if (input_val == '') $(this).next().html('<font color="red">请输入您的年纪.两位数字</font>');
	if (input_val != '') $(this).next().html('<font color="green">输入正确</font>');
	$(this).val(input_val);
});

$('#shengao').click(function(){
	input_val = $.trim($(this).val());
	if (input_val == '') $(this).next().next().next().html('<font color="red">请输入您的身高.三位数字</font>');
	$(this).val(input_val);
}).blur(function(){
	input_val = $.trim($(this).val());
	num_pat = /\d{3,3}/;
	if (num_pat.exec(input_val) == null) {input_val = '';} else {input_val = num_pat.exec(input_val)};
	if (input_val > 195) input_val = '';
	if (input_val < 150) input_val = '';
	if (input_val == '') $(this).next().next().next().html('<font color="red">请输入您的身高.三位数字</font>');
	if (input_val != '') $(this).next().next().next().html('<font color="green">输入正确</font>');
	$(this).val(input_val);
});

$('#tizhong').click(function(){
	input_val = $.trim($(this).val());
	if (input_val == '') $(this).next().next().html('<font color="red">请输入您的体重.二位数字</font>');
	$(this).val(input_val);	
}).blur(function(){
	input_val = $.trim($(this).val());
	num_pat = /\d{2,2}/;
	if (num_pat.exec(input_val) == null) {input_val = '';} else {input_val = num_pat.exec(input_val)};
	if (input_val > 70) input_val = '';
	if (input_val < 30) input_val = '';
	if (input_val == '') $(this).next().next().html('<font color="red">请输入您的体重.二位数字</font>');
	if (input_val != '') $(this).next().next().html('<font color="green">输入正确</font>');
	$(this).val(input_val);
});

$('#fuwu').click(function(){
	input_val = $.trim($(this).val());
	if (input_val == '') $(this).next().html('<font color="red">请输入服务,30字符内.</font>');
	$(this).val(input_val);
}).blur(function(){
	input_val = $.trim($(this).val());
	if (input_val.length > 30) input_val = '';
	if (input_val != '') $(this).next().html('<font color="green">输入正确</font>');
	if (input_val == '') $(this).next().html('');
	$(this).val(input_val);
});

$('#qq').click(function(){
	input_val = $.trim($(this).val());
	if (input_val == '') $(this).next().html('<font color="red">请输入您的QQ号码.</font>');
	$(this).val(input_val);
}).blur(function() {
	input_val = $.trim($(this).val());
	num_pat = /\d{5,12}/;
	if (num_pat.exec(input_val) == null) {input_val = '';} else {input_val = num_pat.exec(input_val)};
	if (input_val == '') $(this).next().html('<font color="red">请输入正确的QQ号码.</font>');
	if (input_val != '') $(this).next().html('<font color="green">输入正确</font>');	
	$(this).val(input_val);
});

$('#shouji').click(function(){
	input_val = $.trim($(this).val());
	if (input_val == '') $(this).next().html('<font color="red">请输入您的手机号码.</font>');
	$(this).val(input_val);
}).blur(function(){
	input_val = $.trim($(this).val());
	num_pat = /\d{11,11}/;
	if (num_pat.exec(input_val) == null) {input_val = '';} else {input_val = num_pat.exec(input_val)};
	if (input_val == '') $(this).next().html('<font color="red">请输入正确的电话号码.</font>');
	if (input_val != '') $(this).next().html('<font color="green">输入正确</font>');
	$(this).val(input_val);
});

$('#jianjie').click(function() {
	input_val = $.trim($(this).val());
	$(this).val(input_val);
}).blur(function() {
	input_val = $.trim($(this).val());
	if (input_val.length > 50 ) $(this).next().html('<font color="red">清输入50个以内的字符</font>');
	if (input_val.length > 50 ) input_val = '';
	if (input_val.length < 50 ) $(this).next().html('<font color="green">输入正确</font>');
	if (input_val == '') $(this).next().html('');
	$(this).val(input_val);
});
//function trim(str) {
//	return str.replace(/(^\s*)|(\s*$)/g, "");
//}

function formsubmit() {
	var submit = true;
	if ($.trim($('#nickname').val()) == '') {
		$('#nickname').next().html('<font color="red">请输入昵称.</font>');
		submit = false;
	}
	
	if ($.trim($('#age').val()) == '') {
		$('#age').next().html('<font color="red">请输入年龄.</font>');
		submit = false;
	}
	
	if ($('#jiguan_guojia').val() == '') {
		alert('请选择籍贯所在省');
		submit = false;
	} else if ($('#jiguan_sheng').val() == '') {
		alert('请选择籍贯所在市');
		submit = false;		
	} else if ($('#jiguan_shi').val() == '' || $('#jiguan_shi').val() == '市辖区') {
		alert('请选择籍贯所在区');
		submit = false;
	}
	
	if ($.trim($('#shengao').val()) == '') {
		$('#shengao').next().next().next().html('<font color="red">请输入身高.</font>');
		submit = false;		
	}
	
	if ($.trim($('#tizhong').val()) == '') {
		$('#tizhong').next().next().html('<font color="red">请输入体重.</font>');
		submit = false;
	}
	
	if ($.trim($('#qq').val()) == '') {
		$('#qq').next().html('<font color="red">请输入QQ.</font>');
		submit = false;
	}
	
	if ($.trim($('#shouji').val()) == '') {
		$('#shouji').next().html('<font color="red">请输入体重.</font>');
		submit = false;
	}		
	
	if (submit) $('#baseform').submit();
}

new PCAS("jiguan_guojia","jiguan_sheng","jiguan_shi","","","");
new PCAS("suozaidi_guojia","suozaidi_sheng","suozaidi_city","上海市","市辖区","");
</script>
</body>
</html>